#!/bin/sh

cp -R /home/etc/ /var/etc/

/sbin/ifconfig em0 inet 192.168.33.33/24 up > /tmp/ssh.log 2>&1
/sbin/ifconfig em1 inet 192.168.11.14/24 up >> /tmp/ssh.log 2>&1
/sbin/ifconfig em2 inet 192.168.22.14/24 up >> /tmp/ssh.log 2>&1
#route add default 192.168.22.22
#route add -net 192.168.111.0/24 192.168.110.1

sleep 1
/usr/sbin/syslogd -P /var/run/syslogd.pid
/usr/local/bin/dropbearkey -t rsa -f /var/etc/ssh_rsa_host_key >> /tmp/ssh.log 2>&1
/usr/local/sbin/dropbear -r /var/etc/ssh_rsa_host_key >> /tmp/ssh.log 2>&1

/sbin/sysctl net.inet.ip.forwarding=1
/sbin/sysctl net.inet.ip.fastforwarding=1

/sbin/pfctl -e
/sbin/pfctl -f /home/xwall/pf.conf

#/sbin/kldload if_tap
#/sbin/pfctl -e
#/usr/local/sbin/mpd4 -p /var/run/mpd.pid -b
#/usr/local/sbin/openvpn --config /pbit/etc/ovpn.conf > /tmp/ovpn.log 2>&1 &
#dnsmasq -i em0 -C /pbit/etc/dnsmasq.conf
#/pbit/bin/minicron 1200 /var/run/cron.pid /pbit/etc/cron.sh
